package com.lnsf.bookstore.system.userLevel.service.impl;

import com.github.pagehelper.PageHelper;
import com.github.pagehelper.PageInfo;
import com.lnsf.bookstore.system.userLevel.dao.UserLevelMapper;
import com.lnsf.bookstore.system.userLevel.service.UserLevelService;
import com.lnsf.bookstore.system.userLevel.vo.UserLevel;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.Map;

@Service
public class UserLevelServiceImpl implements UserLevelService {

	@Autowired
	private UserLevelMapper userLevelMapper;


	@Override
	public UserLevel selectById(Integer id) {
		return userLevelMapper.selectByPrimaryKey(id);
	}

	@Override
	public PageInfo<UserLevel> selectAll(Map<String, Object> map, UserLevel userLevel) {
		PageHelper.startPage(Integer.parseInt(map.get("page").toString()),Integer.parseInt(map.get("limit").toString()));
		return null;
	}

	@Override
	public int save(UserLevel userLevel) {
		return 0;
	}

	@Override
	public int update(UserLevel userLevel) {
		return 0;
	}

	@Override
	public int delete(Integer id) {
		return 0;
	}
}
